#ifndef DEVICE_H
#define DEVICE_H

typedef struct _card_info_t
{
    char device_name[256];
    int device_id;
    int vendor_id;
    int card_type;
}card_info_t;
#define DISCRETE_CARD_TYPE 0xef
#define INTERGRATED_CARD_TYPE 0xfe

typedef struct _device_info
{
#define MAX_CARD_CNT 4
    card_info_t card_info[MAX_CARD_CNT];
    int card_cnt;
}device_info_t;

typedef struct _CARD_CONFIG_INFO
{
    int   card_id;
    char card_name[32];
    char vaapi_path[256];
    char vdpau_path[256];
} CARD_CONFIG_INFO;


extern int get_device_info(device_info_t* device_info);
extern const char* get_vendor_name(int vendor_id);

int load_card_config(const char* configFilePath);
int get_cardinfoindex_byid(int venderid);


extern CARD_CONFIG_INFO* card_config_info;
extern int card_info_nums;


#endif
